Kanzi 3.9.10
KanziView Interface Reference

Common interface for Kanzi view types. More...

Inheritance diagram for KanziView:
[legend]

Public Member Functions

void addListener (KanziViewListener listener)
 Adds state change listener for this view.
 
KanziViewAdapter getAdapter ()
 Gets the adapter of this view.
 
Domain getDomain ()
 Gets the Domain associated with this view.
 
String getName ()
 Gets the name of the view and underlying native view node.
 
Node2D getRoot ()
 Returns the root node of this view.
 
KanziRuntime getRuntime ()
 Gets the KanziRuntime associated with this view.
 
void handleOrientationChange (int orientation)
 Applies device orientation changes to the contents of this view.
 
void removeListener (KanziViewListener listener)
 Removes state change listener from this view.
 
void setClearColor (ColorRGBA color)
 Configures the color used to clear the surface of the view before rendering its contents.
 
void setKzbPathList (String[] kzbPaths)
 Configures the list of kzb files that are loaded when the view is attached.
 
void setName (String name)
 Sets the name for the view and underlying native view node.
 
void setRoot (Node2D node)
 Sets the root node of this view, used to manually set content to the view.
 
void setStartupPrefabUrl (String url)
 Configures the startup prefab that is automatically loaded during initialization.
 

Detailed Description

Common interface for Kanzi view types.

Member Function Documentation

◆ addListener()

void addListener ( KanziViewListener listener)

Adds state change listener for this view.

Parameters
listenerListener to be called when events occur.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ getAdapter()

KanziViewAdapter getAdapter ( )

Gets the adapter of this view.

Returns
Kanzi view adapter of this view.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ getDomain()

Domain getDomain ( )

Gets the Domain associated with this view.

Returns
Domain associated with this view.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ getName()

String getName ( )

Gets the name of the view and underlying native view node.

Returns
Name of the view.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ getRoot()

Node2D getRoot ( )

Returns the root node of this view.

Returns
Root node of this view.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ getRuntime()

KanziRuntime getRuntime ( )

Gets the KanziRuntime associated with this view.

Returns
KanziRuntime associated with this view.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ handleOrientationChange()

void handleOrientationChange ( int orientation)

Applies device orientation changes to the contents of this view.

Parameters
orientationThe orientation qualifier from onOrientationChanged().

Implemented in KanziSurfaceView, and KanziTextureView.

◆ removeListener()

void removeListener ( KanziViewListener listener)

Removes state change listener from this view.

Parameters
listenerListener to remove.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ setClearColor()

void setClearColor ( ColorRGBA color)

Configures the color used to clear the surface of the view before rendering its contents.

Default value: Opaque black i.e. (0, 0, 0, 255).

Parameters
colorColor used to clear the surface of the view. Use null to skip clearing.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ setKzbPathList()

void setKzbPathList ( String[] kzbPaths)

Configures the list of kzb files that are loaded when the view is attached.

Parameters
kzbPathsArray of kzb paths to load.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ setName()

void setName ( String name)

Sets the name for the view and underlying native view node.

Parameters
nameNew name for the view.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ setRoot()

void setRoot ( Node2D node)

Sets the root node of this view, used to manually set content to the view.

Parameters
nodeNode to be displayed in this view.

Implemented in KanziSurfaceView, and KanziTextureView.

◆ setStartupPrefabUrl()

void setStartupPrefabUrl ( String url)

Configures the startup prefab that is automatically loaded during initialization.

Parameters
urlUrl of the prefab template to load.

Implemented in KanziSurfaceView, and KanziTextureView.